import React from "react";
import request from '@/utils/request'
import { Form, Input, Button, Checkbox, Rate ,Switch,InputNumber, message, Divider  } from 'antd'
import { CloseOutlined, CheckOutlined } from '@ant-design/icons'
import confirm from "antd/lib/modal/confirm";
import Bd from "./bd";
let {useEffect,useState,useCallback}=React

function Edit (props){
    const [data1, setdatta] = useState()
    const getdata = useCallback(async () => {
        const { id } = props.match.params;
        const { data } = await request.get(`/goods/id`,  {
            params: {
                _id:id,
            }
        })
        setdatta(data)
     
    },[])
    useEffect( () => {
        getdata()
    },[])
    return (
        <div>
            <Bd data={data1}>
            </Bd>
           </div>
        )
  
}
export default Edit